Release 10.1A: OpenEdge Development:
Programming Interfaces
Input from files
A data file (not a database table) that contains information on new customers might look like the following example:
This file is in standard Progress format. That is, blanks separate the field values. Field values that contain embedded blanks are surrounded by quotation marks (“ ”). Later sections in this chapter discuss using alternate formats.
You can write a Progress procedure and tell that procedure to get its input from the
i-datf1.dfile, as shown in Figure 5–6.Figure 5–6: Redirecting the unnamed input stream
![]()
The
SETstatement, which normally gets its input from the terminal, gets its input from thei-datf1.dfile. The cust–num field uses the first data item, 90. The name field uses the next quoted data item, “Wind Chill Hockey,” etc. Each time Progress processes a data entry statement, it reads one line from the file.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |